function initRootTop() {
    let rootTop = document.querySelector("#root-top")
    rootTop.innerHTML =
        `
    <header>
        <div class="nav">
            <div class="logo">
                <a href="index.html"><img src="img/logo.png" alt="logo"></a>
            </div>
            <div class="nav-link">
                <ul>
                    <li><a href="#" class="nav-link" onclick="gotoIndex()">问答</a></li>
                    <li><a href="#" class="nav-link">博客</a></li>
                    <li><a href="#" class="nav-link">标签</a></li>
                    <li><a href="#" class="nav-link">活动</a></li>
                </ul>
            </div>
            <div class="nav-search">
                <input type="text" id="search-input" name="search" autocomplete="off"
                autocomplete="new-password">
                <button type="button" id="search-button">搜索</button>
            </div>
            <div class="login">
                <a href="#" onclick="openLoginMenu()" id="login-state">用户登录</a>
            </div>
        </div>
    </header>`

    var search_button = document.querySelector("#search-button");
    search_button.onclick = function (){
        var input = document.querySelector("#search-input");
        // console.log(input.value)
        let post_list = document.querySelector("#post-list")
        post_list.innerHTML = ''

        pageStart = 0
        pageCount = 10
        loadPost(pageStart,pageCount,input);
    }

}